﻿<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%@ taglib prefix="s" uri="/struts-tags"%>
<%
	String path = request.getContextPath();
	String basePath = request.getScheme() + "://"
			+ request.getServerName() + ":" + request.getServerPort()
			+ path + "/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<base href="<%=basePath%>">

<title>项目</title>

<meta http-equiv="pragma" content="no-cache">
<meta http-equiv="cache-control" content="no-cache">
<meta http-equiv="expires" content="0">
<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
<meta http-equiv="description" content="This is my page">
<style type="text/css">
#progressBar {width:20px; height:4px; background:#FFFFFF; border:1px solid #000000 padding:1px;}
#progressBarItem {height:8px; background:#C2C8F5;}
</style>
<link href="/sbm/css/table.css" rel="stylesheet" type="text/css" />

<style>
tr{
background:expression_r((this.parentNode.rowIndex)%2==0?"#3DB7CC":"#B3F4FF");
}
</style>
</head>

<body>
	<table width="78%" id="mytab" border="1" class="t1" align="center">
		<tr>
			<th width="10%">项目名称</th>
			<th width="10%">开始时间</th>
			<th width="10%">结束时间</th>
			<th width="5%">状态</th>
			<th width="10%">进度</th>
			<th width="33%">操作</th>
		</tr>
		<s:iterator value="tasklist" id="task">
			<tr>
				<td><a
					href="<s:url action="showallwork">
    		<s:param name="task.taskid" value="#task.taskid"></s:param></s:url>"><s:property value="#task.name" /> <s:hidden name="taskid"
						value="#task.taskid" /></a>
				</td>
				<td><s:property value="#task.startdate" />
				</td>
				<td><s:property value="#task.deadline" />
				</td>
				<td><s:if test="#task.status == 0">不活跃</s:if> <s:else>活跃</s:else>
				</td>
				<td id="progressbar"><s:property value="#task.progress"/>%<div id="progressBarItem" style="width:<s:property value="#task.progress"/>%"></div></td>
			
				<td><a
					href="<s:url action="showallwork">
    		<s:param name="task.taskid" value="#task.taskid"></s:param></s:url>">
						所有相关工作 </a> &nbsp;<a
					href="<s:url action="showallinvolve">
    		<s:param name="task.taskid" value="#task.taskid"></s:param></s:url>">
						相关人员</a> &nbsp;<a
					href="<s:url action="showundowork">
    		<s:param name="task.taskid" value="#task.taskid"></s:param></s:url>">
						未完成工作 </a> &nbsp;<a
					href="<s:url action="showactivework">
    		<s:param name="task.taskid" value="#task.taskid"></s:param></s:url>">
						活跃状态工作 </a> &nbsp; <a
					href="<s:url action="showonetask">
    		<s:param name="task.taskid" value="#task.taskid"></s:param></s:url>">
						修改 </a> &nbsp; <a
					href="<s:url action="deletetask">
			<s:param name="task.taskid" value="#task.taskid"></s:param></s:url>"
					onclick="return confirm('确定删除？')?true:false;">删除 </a>&nbsp;</td>
			</tr>
		</s:iterator>
	</table>
	<table width="78%" id="mytab" border="1" class="t1" align="center">
		<tr>
			<td align="center" colspan="6">共<s:property
					value="#session.tasktotalpage" />页&nbsp;&nbsp;&nbsp;第<s:property
					value="pageNow+1" />页&nbsp;&nbsp;&nbsp; <s:if test="pageNow > 0">
					<a
						href="<s:url action="showalltask"><s:param name="pageNow" value="pageNow-1" /></s:url>">上一页</a>&nbsp;&nbsp;&nbsp;</s:if>
				<s:if test=" pageNow+1 != #session.tasktotalpage">
					<a
						href="<s:url action="showalltask"><s:param name="pageNow" value="pageNow+1" /></s:url>">下一页</a>
				</s:if></td>
		</tr>
	</table>
</body>
</html>
